﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using EntityComponentSystem.Framework;
using EntityComponentSystem.Framework.Math;

namespace EntityComponentSystem.Demos.SpaceAttack.Components
{
    public static class Conversions
    {
        public static ColorEx ToColorEx(this Component2 input)
        {
            return new ColorEx(input["a"], input["r"], input["g"], input["b"]);
        }

        public static Vector2 ToVector2(this Component2 input)
        {
            return new Vector2(input["x"], input["y"]);
        }
    }
}
